var e = require("../../@babel/runtime/helpers/interopRequireDefault").default, t = e(require("../../api/api_CTShare")), a = e(require("../../libs/fecha/index.js")), n = getApp().eventBus;

Page({
    data: {
        endDate: ""
    },
    onLoad: function(e) {
        this.getActInfo();
    },
    onReady: function() {},
    toWebView: function() {
        n.emit("toWebviewPage", {
            url: "https://txwk.10010.com/kcardorder/rules/index.html#/appRule"
        }), wx.navigateTo({
            url: "/pages/webview/index"
        });
    },
    getActInfo: function() {
        var e = this;
        t.default.getActInfo().then(function(t) {
            console.log("获取活动时间接口", t);
            var n = t.code, i = t.result;
            t.msg;
            if ("0" === n) {
                var r = a.default.format(new Date(i.actEndTime), "YYYY[年]MM[月]DD[日]");
                e.setData({
                    endDate: r
                });
            }
        });
    }
});